package edu.yctc.delivery.entity.tag;

import java.util.List;

import com.google.common.collect.ImmutableList;

/**
 * 用户标记类，标记用户是管理员还是配送员
 * 
 * 
 * 
 * @author 渠立庆
 */
public class UserTag {

    /** 管理员 */
    public static final int ADMINISTRATOR = 1;
    /** 配送员 */
    public static final int DELIVERYMAN = 2;

    public static final List<Integer> ALL_USER_TAG = ImmutableList.of(ADMINISTRATOR, DELIVERYMAN);

    public static boolean isLegal(int userTag) {
        for (Integer integer : ALL_USER_TAG) {
            if (integer == userTag) {
                return true;
            }
        }
        return false;
    }

}
